import request from '@/utils/request'

// 查询备货单列表
export function listSub_purchase_order(query) {
  return request({
    url: '/temu/sub_purchase_order/list',
    method: 'get',
    params: query
  })
}

// 查询备货单详细
export function getSub_purchase_order(subPurchaseOrderSn) {
  return request({
    url: '/temu/sub_purchase_order/' + subPurchaseOrderSn,
    method: 'get'
  })
}

// 新增备货单
export function addSub_purchase_order(data) {
  return request({
    url: '/temu/sub_purchase_order',
    method: 'post',
    data: data
  })
}

// 修改备货单
export function updateSub_purchase_order(data) {
  return request({
    url: '/temu/sub_purchase_order',
    method: 'put',
    data: data
  })
}

// 删除备货单
export function delSub_purchase_order(subPurchaseOrderSn) {
  return request({
    url: '/temu/sub_purchase_order/' + subPurchaseOrderSn,
    method: 'delete'
  })
}
